constraint-editor: Don't use g_type_ensure
authorMatthias Clasen <mclasen@redhat.com>
Mon, 25 May 2020 18:14:28 +0000 (14:14 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Mon, 25 May 2020 18:14:28 +0000 (14:14 -0400)
This isn't necessary if we export the get_type function.

demos/constraint-editor/constraint-editor-window.c
demos/constraint-editor/constraint-view.h

index 001eab3ba2d390216a19ab68f22aa347fdce0b4a..ac724993e49d48a2c82de787cc3e2ccb4a05be96 100644 (file)
@@ -487,8 +487,6 @@ constraint_editor_window_class_init (ConstraintEditorWindowClass *class)
   GObjectClass *object_class = G_OBJECT_CLASS (class);
   GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (class);
 
-  g_type_ensure (CONSTRAINT_VIEW_TYPE);
-
   object_class->finalize = constraint_editor_window_finalize;
 
   gtk_widget_class_set_template_from_resource (widget_class,
index 40e80c8c43e243f5493db06f65d0bc1d3a619131..834e606eb71b445e65166239d2aab6470e70543d 100644 (file)
@@ -23,6 +23,7 @@
 
 #define CONSTRAINT_VIEW_TYPE (constraint_view_get_type ())
 
+G_MODULE_EXPORT
 G_DECLARE_FINAL_TYPE (ConstraintView, constraint_view, CONSTRAINT, VIEW, GtkWidget)
 
 ConstraintView * constraint_view_new (void);